<%@page import="com.friday.po.Department"%>
<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
 <head>
		
		<meta http-equiv="Content-Type" content="text/html; charset= UTF-8" />
		<base href="<%=basePath%>">
		<meta http-equiv="Content-Type" content="text/html; charset= UTF-8" />
		<meta http-equiv="pragma" content="no-cache">
		<meta http-equiv="cache-control" content="no-cache">
		<meta http-equiv="expires" content="0">
		<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
		<title>Friday KQ</title>
		
		
		<!-- Reset Stylesheet -->
		<link rel="stylesheet" href="resources/css/reset.css" type="text/css" media="screen" />
	  
		<!-- Main Stylesheet -->
		<link rel="stylesheet" href="resources/css/right.css" type="text/css" media="screen" />
		
		<!-- Invalid Stylesheet. This makes stuff look pretty. Remove it if you want the CSS completely valid -->
		<link rel="stylesheet" href="resources/css/invalid.css" type="text/css" media="screen" />	
		
		<!-- Colour Schemes
	  
		Default colour scheme is green. Uncomment prefered stylesheet to use it.
		
		<link rel="stylesheet" href="resources/css/blue.css" type="text/css" media="screen" />
		
		<link rel="stylesheet" href="resources/css/red.css" type="text/css" media="screen" />  
	 
		-->
		
		<!-- Internet Explorer Fixes Stylesheet -->
		
		<!--[if lte IE 7]>
			<link rel="stylesheet" href="resources/css/ie.css" type="text/css" media="screen" />
		<![endif]-->
		
		<!--                       Javascripts                       -->
  
		<!-- jQuery -->
		<script type="text/javascript" src="resources/scripts/jquery-1.3.2.min.js"></script>
		
		<!-- jQuery Configuration -->
		<script type="text/javascript" src="resources/scripts/simpla.jquery.configuration.js"></script>
		
		<!-- Facebox jQuery Plugin -->
		<script type="text/javascript" src="resources/scripts/facebox.js"></script>
		
		<!-- jQuery WYSIWYG Plugin -->
		<script type="text/javascript" src="resources/scripts/jquery.wysiwyg.js"></script>
		
		<!-- jQuery Datepicker Plugin -->
		<script type="text/javascript" src="resources/scripts/jquery.datePicker.js"></script>
		<script type="text/javascript" src="resources/scripts/jquery.date.js"></script>
         <script type="text/javascript" src="My97DatePicker/WdatePicker.js"></script>
		<!--[if IE]><script type="text/javascript" src="resources/scripts/jquery.bgiframe.js"></script><![endif]-->

		
		<!-- Internet Explorer .png-fix -->
		
		<!--[if IE 6]>
			<script type="text/javascript" src="resources/scripts/DD_belatedPNG_0.0.7a.js"></script>
			<script type="text/javascript">
				DD_belatedPNG.fix('.png_bg, img, li');
			</script>
		<![endif]-->
		
	</head>
  
<body>

<div id="body-wrapper"> <!-- Wrapper for the radial gradient background --><!-- End #sidebar -->
		
  <div id="main-content"> <!-- Main Content Section with everything -->
			
			<noscript> <!-- Show a notification if the user has disabled javascript -->
			</noscript>
			
			<!-- Page Head -->
	   <h2>Welcome to your job<br /></h2>
    <p id="page-intro">Happy Working everyday~<br /></p>
	  <div class="clear">
      <br/>
      <form  action="QueryDepartmentAttendanceServlet.do" method="post">
      <div>
             &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;时间选择：&nbsp;&nbsp;从&nbsp;&nbsp;
             <input class="Wdate" name="startdate" type="text" onclick="WdatePicker()" />
             &nbsp;&nbsp;到&nbsp;&nbsp;
             <input class="Wdate" name="enddate" type="text" onclick="WdatePicker()" />
             &nbsp;
             <select name="department">
                 <%
                 List<Department> deps = (List<Department>)session.getAttribute("deps");
                 for (Department dep : deps) {
                 	out.print("<option value=\"" + dep.getId() + "\">"+dep.getDepName()+"</option>");
                 }
                 %>
             </select>
             &nbsp;
             <input type="submit" value="查询" onclick=""  />
             </div>
       </form>
             <br/><br/>
      </div> 
      <!-- End .clear --><div class="content-box"><!-- Start Content Box --><!-- End .content-box-header -->
				
				<div class="content-box-content">
					
					<div class="tab-content default-tab" id="tab1"> 
					  <table>
							
						  <thead>
								<tr>
								   <th width="14%">部门名称</th>
								   <th width="14%">员工名字</th>
								   <th width="14%">出勤天数</th>
								   <th width="14%">出差天数</th>
                                   <th width="15%">请假天数</th>
								</tr>
								
							</thead>
							<tbody>
								<c:forEach items="${queryattendance }" var="qa">
								<tr>
									<td>
										${qa.depName }
									</td>
									<td>
										${qa.name }
									</td>
									<td>
										${qa.workDay }
									</td>
									<td>
										${qa.evectionDay }
									</td>
									<td>
										${qa.leaveDay }
									</td>
								</tr>
							</c:forEach>
							</tbody>
							
						</table>
						
					</div> 
					<!-- End #tab1 -->
					
					<div class="tab-content" id="tab2"></div> <!-- End #tab2 -->        
					
				</div> <!-- End .content-box-content -->
				
			</div><!-- End .content-box --><!-- End .content-box --><!-- End .content-box -->
    <div class="clear"></div>
			
			
		  <!-- Start Notifications --><!-- End Notifications --><!-- End #footer -->
			
  </div> 
	<!-- End #main-content -->
		
</div>

</body>
  

<!-- Download From www.exet.tk-->
</html>
